<div class="blank10">
</div>
<%= error_messages_for :user_info %>
<div id="title1" align="left">

    <h1 class="padding01">User Info Modify</h1>
</div>
<div id="Tab1">
    <span></span>
    <% form_for @user_info,:url=>{:action=>:update} do |infof| %>
    <div class="Contentbox">
        <div id="con_one_1" class="hover">
            <div class="reginfo">
                <!--user-->
				<% fields_for @user do |f| %>
                <div class="titleName">
                    姓名：
                </div>
                <%= @user.name %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    昵称：
                </div>
                <%= f.text_field :nickname %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    Email：
                </div>
                <%= f.text_field :email %>
                <div class="blank14">
                </div>
				<%end %>
				
                <!--User info-->
                <div class="titleName">
                    地址：
                </div>
                <%= infof.text_field :address %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    邮编：
                </div>
                <%= infof.text_field :postalcode %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    电话：
                </div>
                <%= infof.text_field :telephone %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    相片：
                </div>
                <%= infof.text_field :picture %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    个性图片：
                </div>
                <%= infof.text_field :idiograph %>
                <div class="blank14">
                </div>
                <div class="titleName">
                    城市：
                </div>
                <%= infof.select(:city_id, DCity.find(:all).map {|c| [ c.city_name, c.id ] },{:prompt => "请选择城市"}) %>
                <div class="blank14">
                </div>
                
                <p>
		           <div class="blank20">
		            </div>		
		            <div >
		            	<table cellspacing="20">
		            		<tr>
		            			<td class="btns"><%= link_to '<span>修改</span> ','javascript:document.forms[0].submit(); ' %></td>
								<td class="btns"><%= link_to '<span>取消</span> ', users_path %></td>
								<td class="btns"><%= link_to '<span>下一步</span> ', {:controller=>:personal_management,:action=>:detail,:id=>@user.id} %></td>
		            		</tr>
		            	</table>		               															                
		            </div>                										
                </p>
            </div>
        </div>
    </div>
	
    <% end %>

	<% 
@user_info_errors=(session[:user_info_errors]!=nil)? session[:user_info_errors]:@user_info
%>
<%= error_messages_for :object=>[@user_info_errors] %>
<% session[:user_info_errors]=nil %>
</div>

